
/*This file produces results that are presented in Supplemental Appendix Table S4.  That figure reports the log-odds estimate of the 
Rep. Priority x Context interaction.  This file provides a robustness check of the results using alternative measures of the "new destination state" 
indicator.   Execute this do file with the Stata dataset "microdata_cues.dta." Figure S4 is created in R.  */  


clear
set more off
use "microdata_cues.dta"


/*************************************************************************/
/***************************ALL RESPONDENTS*******************************/
/*************************************************************************/

*This is reported in paper: Model with new destination state interactions.  Results are in lower right panel of Figure 2
*and in the Appendix Table 3, under the column "Model 2." *

*1. Full Model
 ologit immig_self_whole pid libconN incomeI educN moraltrad interestN gender attendchurch retrospect ageN unemp disthispanicpct_10_MC hd0010_MC border newdest1 rep_priority_MC dem_priority_MC nd_rp  if  race==1 [pw=v102], cluster(state) 


/*Specification Tests: Omitting states sequentially from the measure.  The interaction estimate corresponds to plots 2-11 in Figure S4.*/
replace newnd=newdest1
   replace newnd=0 if state_abr=="AR"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN  c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC c.rep_priority_MC##i.newnd   [pw=v102], cluster(state), if race==1 

replace newnd=newdest1

replace newnd=0 if state_abr=="GA"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC c.rep_priority_MC##i.newnd   [pw=v102], cluster(state) , if race==1

   replace newnd=newdest1

replace newnd=0 if state_abr=="IA"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC c.rep_priority_MC##i.newnd  [pw=v102], cluster(state), if race==1 

   replace newnd=newdest1


replace newnd=0 if state_abr=="KY"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC  c.rep_priority_MC##i.newnd   [pw=v102], cluster(state), if race==1 

   replace newnd=newdest1
   
   
replace newnd=0 if state_abr=="MN"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC  c.rep_priority_MC##i.newnd  [pw=v102], cluster(state) , if race==1

   replace newnd=newdest1  
   
 
replace newnd=0 if state_abr=="NC"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC  c.rep_priority_MC##i.newnd   [pw=v102], cluster(state), if race==1 

   replace newnd=newdest1   
   
   
replace newnd=0 if state_abr=="NE"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC c.rep_priority_MC##i.newnd  [pw=v102], cluster(state), if race==1 

   replace newnd=newdest1 
   
 
replace newnd=0 if state_abr=="NV"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC c.rep_priority_MC##i.newnd   [pw=v102], cluster(state), if race==1 

   replace newnd=newdest1  
   
replace newnd=0 if state_abr=="SC"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC  c.rep_priority_MC##i.newnd  [pw=v102], cluster(state) , if race==1

   replace newnd=newdest1     

replace newnd=0 if state_abr=="TN"

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.dem_priority_MC  c.rep_priority_MC##i.newnd  [pw=v102], cluster(state), if race==1

   replace newnd=newdest1     


*12. Change in State Hispanic*
ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN  c.unemp c.disthispanicpct_10_MC c.hd0010_MC  c.hisp2010state_MC c.hs9010_1k_MC##c.rep_priority_MC c.dem_priority_MC  [pw=v102], cluster(state) , if race==1


*13. Change in State Foreign Born
/*
gen rp_stateDF=fs9010_1k_MC*rep_priority_MC
*/
  

ologit immig_self_whole pid libconN incomeI educN moraltrad interestN gender attendchurch retrospect ageN unemp disthispanicpct_10_MC hd0010_MC for2010state_MC fs9010_1k_MC rep_priority_MC dem_priority_MC rp_stateDF  [pw=v102], cluster(state) , if race==1



*14. Change in State Unauthorized

/*
summ ua2010state
gen ua2010state_MC=ua2010state-r(mean)


summ uachange9010
   gen uachange9010_MC=uachange9010-r(mean)	
   gen uachange9010_MC_1k=uachange9010_MC/1000
   gen rp_stateDU=uachange9010_MC_1k*rep_priority_MC
 */
 
ologit immig_self_whole pid libconN incomeI educN moraltrad interestN gender attendchurch retrospect ageN unemp disthispanicpct_10_MC hd0010_MC ua2010state_MC  uachange9010_MC_1k rep_priority_MC dem_priority_MC rp_stateDU  [pw=v102], cluster(state) , if race==1

*15. Summative Measure
/*
alpha hisp2010state_MC  ua2010state_MC  for2010state_MC, gen(statepop)

alpha hs9010_1k_MC  uachange9010_MC_1k  fs9010_1k_MC, gen(statechange)

gen rp_stateDS=statechange*rep_priority_MC
 */

ologit immig_self_whole pid libconN incomeI educN moraltrad interestN gender attendchurch retrospect ageN unemp disthispanicpct_10_MC hd0010_MC statepop statechange rep_priority_MC dem_priority_MC rp_stateDS   [pw=v102], cluster(state), if race==1 

*16. Excluding Latino Respondents but including all other races/ethnicities.

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN  c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.rep_priority_MC##i.newdest1 c.dem_priority_MC  if  race~=3 [pw=v102], cluster(state) 

*17. Including ALL Respondents including Latinos

ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN  c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.rep_priority_MC##i.newdest1 c.dem_priority_MC   [pw=v102], cluster(state) 

*18. Including only Likely Voters, All Respondents
/*
gen likelyvoter=cc354
   replace likelyvoter=1 if cc354==1 | cc354==2
   replace likelyvoter=0 if likelyvoter==3 | likelyvoter==4 | likelyvoter==.
*/
ologit immig_self_whole c.pid c.libconN c.incomeI c.educN c.moraltrad c.interestN i.gender c.attendchurch c.retrospect c.ageN  c.unemp c.disthispanicpct_10_MC c.hd0010_MC i.border i.newdest1 c.rep_priority_MC##i.newdest1 c.dem_priority_MC if race==1 & likelyvoter==1 [pw=v102], cluster(state) 

